import App from './App'
import uView from '@/uni_modules/uview-ui'
import Vue from 'vue'
import store from "./store"

/*挂载封装api到实例prototype上*/
import api from "@/request/api.js"
Vue.prototype.$store = store
Vue.prototype.$api = api
Vue.config.productionTip = false
App.mpType = 'app'
Vue.use(uView)
import $C from '@/common/lib/config.js';
Vue.prototype.$C = $C
// 引入全局组件
import commonPrice from "@/compontents/common/common-price.vue";
import commonButton from "@/compontents/common/common-button.vue";
import commonPath from "@/compontents/common/common-path.vue";
import commonItem from "@/compontents/common/common-item.vue";
import commonPay from "@/compontents/common/common-pay.vue";
import orderItem from "@/compontents/common/order-item.vue";
import zcmradioGroup from "@/compontents/common/radio-group.vue";
import card from "@/compontents/common/card.vue"
import colorTag from "@/compontents/common/color-tag.vue"
import orderButton from "@/compontents/common/common-order-button.vue"
import commonNews from "@/compontents/common/common-news.vue"
import orderTop from "@/compontents/common/common-order-top.vue"
import electronicInvoice from "@/compontents/common/electronic-invoice.vue"

Vue.component('commonPrice', commonPrice)
Vue.component('commonButton', commonButton)
Vue.component('commonPay', commonPay)
Vue.component('orderItem', orderItem)
Vue.component('zcmradioGroup', zcmradioGroup)
Vue.component('commonPath', commonPath)
Vue.component('card', card)
Vue.component('colorTag', colorTag)
Vue.component('commonItem', commonItem)
Vue.component('orderButton', orderButton)
Vue.component('commonNews', commonNews)
Vue.component('orderTop', orderTop)
Vue.component('electronicInvoice', electronicInvoice)

// 引入uView对小程序分享的mixin封装
let mpShare = require('@/uni_modules/uview-ui/libs/mixin/mpShare.js');
Vue.mixin(mpShare)

const app = new Vue({
    ...App,
	 store
})
/*引入请求封装，将app参数传递到配置中*/
require('@/request/request.js')(app)
app.$mount()


